package com.zjh.shop.client;

import com.zjh.shop.dto.DemoInputDTO;
import com.zjh.shop.fallback.UserClientFallBackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@Component
@FeignClient(name = "item-user",fallbackFactory = UserClientFallBackFactory.class)
public interface UserFeignClient {
    @PostMapping("/user/hello")
    String hello(@RequestBody DemoInputDTO inputDTO);

    @GetMapping("/user")
    String show();
}
